package ar.com.fiuba.RulesMgr.rules;

import java.util.List;

import ar.com.fiuba.RulesMgr.validationModes.ValidationMode;

/**
 * Abstract class to be implemented in order to have a rule that validates
 * objects with business logic.
 * 
 */
public abstract class Rule extends GenericRule {

	/**
	 * {@link GenericRule#validateWithMode(ValidationMode, List)}
	 */
	@Override
	public final Boolean validateWithMode(ValidationMode mode, List<Object> objects) {
		return modifier.apply(validate(objects));
	}

}
